<?php
require_once("DButil.php");
$teacherName=$_REQUEST["tname"];
$sql="select teacherId,teacherName,username,roleName,status from t_teacher t1 left join t_role t2 on t1.roleId=t2.roleId where teacherName='{$teacherName}' ";
$arr=query($sql)[0];
header("Content-Type:application/json;charset=utf-8");
echo json_encode($arr);
?>